<template>
 <div class="box">
  <Header title="旅游行程"></Header>
  <div class="trip-title-box">
    <span>经典路线</span>
    <router-link to="creatTrip">创建行程</router-link>
  </div>
  <router-link to="tripDetail" class="trip-item" v-for="(item,index) in tripList" :key="index">
    <div class="img-box">
      <img :src="item.banner" alt="">
    </div>
    <h3 class="trip-item-title">{{item.title}}</h3>
    <div class="trip-item-tag">
      <span v-for="(tag,i) in item.tag" :Key="i">{{tag}}</span>
    </div>
    <p class="trip-item-p">{{item.time}}</p>
  </router-link>
  <!-- <router-link to="tripDetail" class="trip-item">
    <div class="img-box">
      <img src="@/assets/temporary/trip-item2.png" alt="">
    </div>
    <h3 class="trip-item-title">少林寺经典1日游</h3>
    <div class="trip-item-tag">
      <span>初次必玩</span>
      <span>探秘少林武术发源地</span>
      <span>观看少林武僧精彩表演</span>
      <span>山林之间赏乐大典</span>
    </div>
    <p class="trip-item-p">最佳季节：春节、秋季</p>
  </router-link> -->
  <Nav :Active="1"></Nav>
 </div>
</template>

<script>
import Header from '@/components/Header/Header'
import Nav from '@/components/Nav/Nav'
import item1 from'@/assets/temporary/trip-item1.png'
import item2 from'@/assets/temporary/trip-item2.png'
export default {
name:'Trip',
components:{Header,Nav},
data(){
  return{
      tripList:[{banner:item1,title:'少林寺经典1日游',tag:['初次必玩','探秘少林武术发源地','观看少林武僧精彩表演','山林之间赏乐大典'],time:'最佳季节：春季、秋季'},{banner:item2,title:'河南旅游局推荐精华6日线路',tag:['初次必玩','官方推荐','云台山仙境游','天下功夫出少林'],time:'最佳季节：春季、秋季'}]
  }
}
}
</script>

<style lang="less" scope>
.trip-title-box{
  display: flex;
  justify-content: space-between;
  height: 100/7.5vw;
  align-items: center;
  color: #0FD2B2;
  font-size: 36/7.5vw;
  a{
    display: block;
    width: 160/7.5vw;
    height: 56/7.5vw;
    border-radius: 10/7.5vw;
    background-color: #0FD2B2;
    color: #fff;
    font-size: 32/7.5vw;
    text-align: center;
    line-height: 56/7.5vw;
  }
}
.trip-item{
  display: block;
  .img-box{
    height: 400/7.5vw;
    border-radius: 10/7.5vw;
    overflow: hidden;
    img{
      display: block;
      width: 100%;
    }
  }
  .trip-item-title{
    font-size: 36/7.5vw;
    line-height: 72/7.5vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .trip-item-tag{
    display: flex;
    flex-wrap: wrap;
    >span{
      padding:0 8/7.5vw;
      margin-right:10/7.5vw;
      margin-bottom: 10/7.5vw;
      border: 1px solid #E7BC79;
      border-radius: 6/7.5vw;
      font-size: 24/7.5vw;
      text-align: center;
      color: #E7BC79;
    }
  }
  .trip-item-p{
    font-size: 28/7.5vw;
    line-height: 62/7.5vw;
  }
}
</style>